import {commomParams,options} from "api/config.js"
import jsonp from "commom/js/jsonp.js"
export function getranklist(){
  const url = 'https://c.y.qq.com/v8/fcg-bin/fcg_myqq_toplist.fcg';
  let data = {
    g_tk: 1928093487,
    inCharset: 'utf-8',
    notice: 0,
    format: 'jsonp',
    uin: 0,
    needNewCode: 1,
    platform: 'h5'
  }
  let urldata = Object.assign({},commomParams,data);
  return jsonp(url,urldata,options)
}

export function getTopList(id){
  const url = 'https://c.y.qq.com/v8/fcg-bin/fcg_v8_toplist_cp.fcg';
  let data = {
    g_tk: 1928093487,
    format: 'jsonp',
    topid: id,
    uin: 0,
    tpl: 3,
    page: 'detail',
    type: 'top',
    platform: 'h5'
  }
  let urldata = Object.assign({},commomParams,data);
  return jsonp(url,urldata,options)
}
